<%@page import="com.xx.entity.Message"%>
<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>


<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    
    <title>My JSP 'msg.jsp' starting page</title>
    
    <meta http-equiv="Refresh" content="2" />
	

  </head>
  
  <body>
   	<%
  		List<Message> msgList = (List<Message>)application.getAttribute("msgList");
  		if(msgList != null) {
  			for(Message msg : msgList) {
  	%>
  
    <div>
    	<h4><%=msg.getTime() %>&nbsp;&nbsp;&nbsp;<%=msg.getName() %></h4>
    	<p>
    		<%=msg.getMsg() %>
    	</p>
    </div>
    
    <%}}%>
   
  </body>
</html>
